import 'package:flutter/material.dart';
import 'package:fzcgx_app/common/adapter_utils.dart';
import 'package:fzcgx_app/common/assets_utils.dart';

// ignore: must_be_immutable
class EmptyWidget extends StatefulWidget {
  String emptyText;
  EmptyWidget({Key key, this.emptyText}) : super(key: key);
  @override
  _EmptyWidgetState createState() => _EmptyWidgetState();
}

class _EmptyWidgetState extends State<EmptyWidget> {
  @override
  Widget build(BuildContext context) {
    return Container(
      width: AdapterUtils.getWidth(198),
      height: AdapterUtils.getHeight(163),
      child: Stack(
        children: <Widget>[
          Container(
            width: AdapterUtils.getWidth(198),
            height: AdapterUtils.getHeight(163),
            child: Image.asset(
              AssetsUtils.getAssetsImagesPath('empty.png'),
              fit: BoxFit.cover,
            ),
          ),
        Center(
           
            child: Container(
              padding: EdgeInsets.only(top: AdapterUtils.getHeight(100)),
              child: Text(widget.emptyText, style: TextStyle(
                            color: Color(0xff99A2AD),
                            fontWeight: FontWeight.w500,
                            fontSize: AdapterUtils.getSp(12))),
            )
          )
        ],
      ),
    );
  }
}
